<%@ page import="pildemil.Projet" %>
<%@ page import="pildemil.Participant" %>
<html>
    <head>
        <meta name="layout" content="main" />
    </head>
    
    <body>
		<div data-role="page">		
		    <g:form name="formulaire" action="sauver">
			    <div data-role="header">
				    <h1>Modif. participant</h1>
			    </div>
			    
			    <div data-role="content">
			    	<g:if test="${message}">
			    		<p class="erreur">${message}<p>
			    	</g:if>
			    
				    <input id="id" type="hidden" name="id" value="${participant?.key?.id}" />
				        
				    <div data-role="fieldcontain">
					    <label for="nom"><em>* </em>Nom</label>
					    <g:textField name="nom" value="${participant?.nom}" minlength="3" maxlength="50" class="required" />
				    </div>
				    
				    <div data-role="fieldcontain">
					    <label for="email">E-mail</label>
					    <g:textField name="email" value="${participant?.email}" maxlength="100" class="email" />
				    </div>
				    
				    <div data-role="fieldcontain">
					    <label for="part"><em>* </em>Nombre de parts</label>
					    <g:textField name="part" value="${participant?.part}" class="required number" />
				    </div>
				    
				    <fieldset class="ui-grid-a">
		        		<div class="ui-block-a"><g:link controller="participant" action="liste" data-role="button" data-icon="arrow-l">Annuler</g:link></div>
						<div class="ui-block-b"><g:submitButton name="sauver" value="OK" data-icon="check" data-theme="b"/></div>
	        		</fieldset>
				</div>
            </g:form>
	        
	        <script type="text/javascript">
    			$('[data-role=page]').live('pageshow', function () {   
  			    	$('#formulaire').validate();
  				});
	        </script>
		</div>
	</body>
</html>
